<include file="Public:header" />
<div class="pad_lr_10" >
    <form name="searchform"  method="get" >
        <table width="100%" cellspacing="0" class="search_form">
            <tbody>
            <tr>
                <td>
                    <div class="explain_col">
                        <input type="hidden" name="m" value="Admin" />
                        <input type="hidden" name="c" value="HotKey" />
                        <input type="hidden" name="a" value="index" />
                        <input type="hidden" name="menuid" value="{$menuid}" />
                        选择分类：
                        <select class="J_cate_select mr10" data-pid="0" data-uri="{:U('TaobaokeCate/ajax_getchilds')}" data-selected="{$search.selected_ids}"></select>
                        <input type="hidden" name="cate_id" id="J_cate_id" value="{$search.cate_id}" />
                        &nbsp;&nbsp;{:L('status')}:
                        <select name="status">
                            <option value="">-{:L('all')}-</option>
                            <option value="1" <if condition="$search.status eq '1'">selected="selected"</if>>已审核</option>
                            <option value="0" <if condition="$search.status eq '0'">selected="selected"</if>>未审核</option>
                        </select>
                        &nbsp;&nbsp;{:L('keyword')} :
                        <input name="keyword" type="text" class="input-text" size="25" value="{$search.keyword}" />
                        <input type="submit" name="search" class="btn" value="{:L('search')}" />
                    </div>
                </td>
            </tr>
            </tbody>
        </table>
    </form>
    <div class="J_tablelist table_list" data-acturi="{:U('HotKey/ajax_edit')}">
        <table width="100%" cellspacing="0">
            <thead>
            <tr>
                <th width=25><input type="checkbox" id="checkall_t" class="J_checkall"></th>
                <th><span tdtype="order_by" fieldname="id">ID</span></th>
                <th align="left" width="200"><span data-tdtype="order_by" data-field="name">名称</span></th>
                <th width="100">分类</th>
                <th align="left"><span data-tdtype="order_by" data-field="url">链接地址</span></th>
                <th>热搜</th>
                <th width="40"><span data-tdtype="order_by" data-field="status">{:L('status')}</span></th>
                <th width="80">{:L('operations_manage')}</th>
            </tr>
            </thead>
            <tbody>
            <volist name="lists" id="val" >
                <tr>
                    <td align="center">
                        <input type="checkbox" class="J_checkitem" value="{$val.id}"></td>
                    <td align="center">{$val.id}</td>
                    <td align="left"><span data-tdtype="edit" data-field="name" data-id="{$val.id}" class="tdedit">{$val.name}</span></td>
                    <td align="center">{$val.catname}</td>
                    <td align="center"><b>{$val.url}</b></td>
                    <td align="center"><if condition="$val['hot'] eq 1">是<else />否</if></td>
                    <td align="center"><img data-tdtype="toggle" data-id="{$val.id}" data-field="status" data-value="{$val.status}" src="__IMG__/admin/toggle_<if condition="$val.status eq 0">disabled<else/>enabled</if>.gif" /></td>
                    <td align="center">
                        <a href="javascript:;" class="J_showdialog" data-uri="{:U('HotKey/edit', array('id'=>$val['id']))}" data-title="{:L('edit')} - {$val.name}"  data-id="edit" data-acttype="ajax" data-width="500" data-height="200">{:L('edit')}</a>
                    <a href="javascript:;" class="J_confirmurl" data-acttype="ajax" data-uri="{:U('HotKey/delete', array('id'=>$val['id']))}" data-msg="{:sprintf(L('confirm_delete_one'),$val['name'])}">{:L('delete')}</a>
                    </td>
                </tr>
            </volist>
            </tbody>
        </table>
    </div>
    <div class="btn_wrap_fixed">
        <label><input type="checkbox" name="checkall" class="J_checkall">{:L('select_all')}/{:L('cancel')}</label>
        <input type="button" class="btn" data-tdtype="batch_action" data-acttype="ajax" data-uri="{:U('HotKey/delete')}" data-name="id" data-msg="{:L('confirm_delete')}" value="{:L('delete')}" />
        <div id="pages">{$page}</div>
    </div>
</div>
<include file="Public:footer" />
<script>
    $('.J_cate_select').cate_select({top_option:lang.all});

</script>
</body>
</html>